import java.util.Scanner;

public class Ex4_16{
	public static void main(String[] args){
		Scanner input = new Scanner(System.in);
		System.out.print("Enter an integer: ");
		int n = input.nextInt();
		int f = 2;
		while (f <= n){
			if (n % f == 0){
				n /= f;
				System.out.printf("%d ", f);
			}
			else
				f++;
		}

	}
}